<template>
<!-- 总账 -->
    <div>
        <Navs></Navs>
        <div class="menuleft">
            <el-col>
                <el-menu :default-active="activeIndex" class="el-menu-vertical-demo">
                    <el-menu-item index="1" class="li-back-index">
                        <router-link to="/home">
                            <i class="el-icon-d-arrow-left"></i>&nbsp;返回首页
                        </router-link>
                    </el-menu-item>
                     <el-menu-item index="2">
                        <router-link to="/keeper">
                            <i class="fa fa-user-secret"></i>期初余额</router-link>
                    </el-menu-item>
                    <el-menu-item index="3" @click="isshow1 = !isshow1" class="li-title">
                        <i class="el-icon-caret-bottom"></i>凭证</el-menu-item>
                    <el-menu-item index="3" v-for="(gg,index) in gonggong" :key="index" v-show="isshow1" class="li-items">
                        <router-link :to="gg.id">
                            {{gg.name}}
                        </router-link>
                    </el-menu-item>
                    <el-menu-item index="4">
                        <router-link to="/finance">
                            <i class="fa fa-credit-card-alt"></i>财务处理</router-link>
                    </el-menu-item>
                    <el-menu-item index="5" @click="isshow2 = !isshow2" class="li-title">
                        <i class="icon iconfont icon-zhangben"></i>账簿</el-menu-item>
                    <el-menu-item index="5" v-for="(cw,index) in caiwu" :key="index" v-show="isshow2" class="li-items">
                        <router-link :to="cw.id">
                            {{cw.name}}
                        </router-link>
                    </el-menu-item>
                    <el-menu-item index="6" @click="isshow3 = !isshow3" class="li-title">
                        <i class="icon iconfont icon-baobiao1"></i>报表</el-menu-item>
                    <el-menu-item index="4" v-for="(xt,index) in xitong" :key="index" v-show="isshow3" class="li-items">
                        <router-link :to="xt.id">
                            {{xt.name}}
                        </router-link>
                    </el-menu-item>
                </el-menu>
            </el-col>
        </div>
        <router-view></router-view>
    </div>
</template>
<script>
import Navs from '../Navs.vue'
export default {
    name: "money",
    components: {
        Navs
    },
    data() {
        return {
            activeIndex: "1",
            isshow1: false,
            isshow2: false,
            isshow3: false,
            gonggong: [
                { name: '编制', id: 'keeperbz' },
                { name: '审核', id: 'keepersh' },
                { name: '记账', id: 'keeperjz' },
                { name: '损益结转', id: 'keeperloss' },
                 { name: '查询', id: 'keeperquery' },
                  { name: '模板', id: 'template' }
            ],
            caiwu: [
                { name: '总账', id: 'overall' },
                { name: '明细账', id: 'detail' },
                { name: '核算明细账', id: 'checkingdt' }
            ],
            xitong: [
                { name: '资产负债表', id: 'Lose' },
                { name: '利润表', id: 'profit' },
                { name: '现金流量表', id: 'cash' },
                { name: '资金头寸表', id: 'fund' }
            ],
        }
    }
}   
</script>
<style scoped>
@import '../../common/css/index.css';
.menuleft {
    height: calc(100vh - 60px);
}

</style>
